package com.config;

import com.entity.Car;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

@Configuration
@ComponentScan(basePackages = "com")
public class MySpringConfiguration {

    @Bean("car4")
    public Car initCar4(){
        return new Car("BYD","red",120000);
    }
}
